package com.tianlh.service.design_pattern.Decorator;

/**
 * Created by wb-tianlihui on 2017/11/21.
 */
public class QDecorator extends Decorator {

    private final String SKILL_NAME = "致盲吹箭";
    /**
     * 构造方法，传入组件对象
     * @param component 组件对象
     */
    public QDecorator(HeroComponent component) {
        super(component);
    }

    public void customFunction(){
        System.out.println("我拥有了Q技能:" + SKILL_NAME);
    }

    @Override
    public void Pugong() {
        super.Pugong();
        customFunction();
    }
}